﻿using DataModel.Models;
using System;
using System.Collections.Generic;
using System.Configuration;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace DataModel.Contants
{
    public class AppDefines
    {
        public const string AppName = "appName";//应用名称

        public const string Version = "version";//版本

        public const string MainView = "mainView";//主页模式版本

        public const string Config = "config";//配置文件

        public const string Wallpaperindex = "wallpaperindex";//壁纸索引

        public const string Playlist = "playlist";//播放列表

        public const string SourceMode = "mode";//壁纸系统模式

        public static OssConfig OssConfig = new OssConfig();

        public static string GetMainWindowTitle
        {
            get
            {
                return ConfigurationManager.AppSettings[AppName] + " " + ConfigurationManager.AppSettings[Version];
            }
        }

        /// <summary>
        /// 获取主页版本，默认V3版本
        /// </summary>
        public static string GetMainWindowVersion => ConfigurationManager.AppSettings[MainView] ?? "V3";

        /// <summary>
        /// 获取壁纸系统模式，默认bmp模式
        /// </summary>
        public static string GetSourceMode => ConfigurationManager.AppSettings[SourceMode] ?? "bmp";
    }
}
